package com.peace.hospital.mapper;

import com.baomidou.mybatisplus.core.mapper.BaseMapper;


import com.peace.hospital.entity.common.Department;
import org.apache.ibatis.annotations.Mapper;
import org.apache.ibatis.annotations.Select;

import java.util.List;

/**
 * <p>
 * 科室表 Mapper 接口
 * </p>
 *
 * @author xie
 * @since 2019-11-12
 */
@Mapper
public interface DepartmentMapper extends BaseMapper<Department> {



    /**
     * 查询所有科室名字对页面做动态管理
     * @param
     * @return
     */
    @Select("select depid，deptype from hospital_public.department")
    List<Department> selectDepartmentList();

    /**
     * 查询员工对应的科室名字
     * @param depid
     * @return
     */
    @Select("select deptype from hospital_public.department where depid=#{depid}")
    Department selectDepartment(int depid);

//    /**
//     * 修改员工对应的科室名字
//     *
//     *
//     * @return
//     */
//    @Update("update hospitalization.department set deptype=#{department} where depid=#{department}")
//
//    Integer updatePosition(@Param("department") Department department );




}
